package nl.hu.verbrandendephoenix.shared;

import java.io.Serializable;
import java.util.Date;

/*
CREATE TABLE VEILING 
(
  VEILINGID NUMBER NOT NULL 
, VEILINGNAAM VARCHAR2(32 BYTE) NOT NULL 
, MINBOD NUMBER NOT NULL 
, STARTDATUM DATE NOT NULL 
, USERID NUMBER NOT NULL 
, OMSCHRIJVING VARCHAR2(1000 BYTE) NOT NULL 
, CATEGORIE VARCHAR2(32 BYTE) NOT NULL 
, CONSTRAINT VEILING_PK PRIMARY KEY 
  (
    VEILINGID 
  )
  ENABLE 
);
*/

public class Auction implements Serializable {

	private int auctionID;
	private String auctionName;
	private String category;
	private double iniPrice;
	private String description;
	private int userID;
	private Date endDate;
	
	public Auction() {}
	
	public Auction(String aN, int aID) {
		auctionName = aN;
		auctionID = aID;
	}
	
	public Auction(String aN, String cat, double pr, String desc, int UID, Date end) {
		auctionName = aN;
		category = cat;
		iniPrice = pr;
		description = desc;
		userID = UID;
		endDate = end;
	}
	
	/*
	 * Getters
	 */
	
	public String getAuctionName() {
		return auctionName;
	}
	
	public String getCategory() {
		return category;
	}
	
	public double getIniPrice() {
		return iniPrice;
	}
	
	public String getDescription() {
		return description;
	}
	
	public int getUserID() {
		return userID;
	}
	
	public Date getEndDate() {
		return endDate;
	}
	
	public int getAuctionID() {
		return auctionID;
	}
	
	
	/*
	 * Setters
	 */
	
	public void setAuctionName(String aN) {
		auctionName = aN;
	}
	
	public void setDescription(String desc) {
		description = desc;
	}
	
	public void setCategory(String cat) {
		category = cat;
	}
	
	public void setIniPrice(double pr) {
		iniPrice = pr;
	}
	
	public void setUserID(int id) {
		userID = id;
	}
	
	public void setEndDate(Date dt) {
		endDate = dt;
	}
	
	public void setAuctionID(int aid) {
		auctionID = aid;
	}
	
	public String toString() {
		return "Ja dat zuigt, je ID is: " + getAuctionID() + ". Je naam is: " + getAuctionName();
	}
}
